XCopyArea with subwindow_mode = IncludeInferiors. (#70999)
authorOwen Taylor <otaylor@redhat.com>
Sat, 9 Feb 2002 05:24:25 +0000 (05:24 +0000)
committerOwen Taylor <otaylor@src.gnome.org>
Sat, 9 Feb 2002 05:24:25 +0000 (05:24 +0000)
Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>

        * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image):
        XCopyArea with subwindow_mode = IncludeInferiors.
        (#70999)

        * demos/testpixbuf-save.c (configure_cb): Fix a minor
        memory management problem.

ChangeLog
ChangeLog.pre-2-0
ChangeLog.pre-2-10
ChangeLog.pre-2-2
ChangeLog.pre-2-4
ChangeLog.pre-2-6
ChangeLog.pre-2-8
demos/testpixbuf-save.c
gdk/x11/gdkimage-x11.c

index 8ceaed0b54c48b9fe2b12da724e372ec14715357..afd761312210c5bede600ae22f1b8becc88ee9b8 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,12 @@
+Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image): 
+       XCopyArea with subwindow_mode = IncludeInferiors.
+       (#70999)
+
+       * demos/testpixbuf-save.c (configure_cb): Fix a minor
+       memory management problem.
+
 Fri Feb  8 20:24:58 2002  Owen Taylor  <otaylor@redhat.com>
 
        
index 8ceaed0b54c48b9fe2b12da724e372ec14715357..afd761312210c5bede600ae22f1b8becc88ee9b8 100644 (file)
@@ -1,3 +1,12 @@
+Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image): 
+       XCopyArea with subwindow_mode = IncludeInferiors.
+       (#70999)
+
+       * demos/testpixbuf-save.c (configure_cb): Fix a minor
+       memory management problem.
+
 Fri Feb  8 20:24:58 2002  Owen Taylor  <otaylor@redhat.com>
 
        
index 8ceaed0b54c48b9fe2b12da724e372ec14715357..afd761312210c5bede600ae22f1b8becc88ee9b8 100644 (file)
@@ -1,3 +1,12 @@
+Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image): 
+       XCopyArea with subwindow_mode = IncludeInferiors.
+       (#70999)
+
+       * demos/testpixbuf-save.c (configure_cb): Fix a minor
+       memory management problem.
+
 Fri Feb  8 20:24:58 2002  Owen Taylor  <otaylor@redhat.com>
 
        
index 8ceaed0b54c48b9fe2b12da724e372ec14715357..afd761312210c5bede600ae22f1b8becc88ee9b8 100644 (file)
@@ -1,3 +1,12 @@
+Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image): 
+       XCopyArea with subwindow_mode = IncludeInferiors.
+       (#70999)
+
+       * demos/testpixbuf-save.c (configure_cb): Fix a minor
+       memory management problem.
+
 Fri Feb  8 20:24:58 2002  Owen Taylor  <otaylor@redhat.com>
 
        
index 8ceaed0b54c48b9fe2b12da724e372ec14715357..afd761312210c5bede600ae22f1b8becc88ee9b8 100644 (file)
@@ -1,3 +1,12 @@
+Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image): 
+       XCopyArea with subwindow_mode = IncludeInferiors.
+       (#70999)
+
+       * demos/testpixbuf-save.c (configure_cb): Fix a minor
+       memory management problem.
+
 Fri Feb  8 20:24:58 2002  Owen Taylor  <otaylor@redhat.com>
 
        
index 8ceaed0b54c48b9fe2b12da724e372ec14715357..afd761312210c5bede600ae22f1b8becc88ee9b8 100644 (file)
@@ -1,3 +1,12 @@
+Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image): 
+       XCopyArea with subwindow_mode = IncludeInferiors.
+       (#70999)
+
+       * demos/testpixbuf-save.c (configure_cb): Fix a minor
+       memory management problem.
+
 Fri Feb  8 20:24:58 2002  Owen Taylor  <otaylor@redhat.com>
 
        
index 8ceaed0b54c48b9fe2b12da724e372ec14715357..afd761312210c5bede600ae22f1b8becc88ee9b8 100644 (file)
@@ -1,3 +1,12 @@
+Sat Feb  9 00:16:31 2002  Owen Taylor  <otaylor@redhat.com>
+
+       * gdk/x11/gdkimage-x11.c (_gdk_x11_copy_to_image): 
+       XCopyArea with subwindow_mode = IncludeInferiors.
+       (#70999)
+
+       * demos/testpixbuf-save.c (configure_cb): Fix a minor
+       memory management problem.
+
 Fri Feb  8 20:24:58 2002  Owen Taylor  <otaylor@redhat.com>
 
        
index f592ffc4554a83c5aa969f9b61414089bdf62cfa..2c589d227bec3af4caa42e8fa7ff49f771ffba2c 100644 (file)
@@ -204,8 +204,8 @@ configure_cb (GtkWidget *drawing_area, GdkEventConfigure *evt, gpointer data)
                 root = gdk_get_default_root_window ();
                 new_pixbuf = gdk_pixbuf_get_from_drawable (NULL, root, NULL,
                                                            0, 0, 0, 0, evt->width, evt->height);
-                g_object_set_data (G_OBJECT (drawing_area), "pixbuf", new_pixbuf);
-                g_object_unref (pixbuf);
+                g_object_set_data_full (G_OBJECT (drawing_area), "pixbuf", new_pixbuf,
+                                        (GDestroyNotify) g_object_unref);
         }
 
         return FALSE;
index c1de3d2a3d5f93e1f30372d79dcd74e7ed748738..8b3bf6036e3c0fcc622c1c11dbe25ce95bc26360 100644 (file)
@@ -506,9 +506,13 @@ _gdk_x11_copy_to_image (GdkDrawable    *drawable,
       shm_pixmap = _gdk_x11_image_get_shm_pixmap (image);
       if (shm_pixmap)
        {
+         GC xgc;
+         XGCValues values;
+
          /* Again easy, we can just XCopyArea, and don't have to worry about clipping
           */
-         GC xgc = XCreateGC (impl->xdisplay, impl->xid, 0, NULL);
+         values.subwindow_mode = IncludeInferiors;
+         xgc = XCreateGC (impl->xdisplay, impl->xid, GCSubwindowMode, &values);
          
          XCopyArea (impl->xdisplay, impl->xid, shm_pixmap, xgc,
                     src_x, src_y, width, height, dest_x, dest_y);